package com.hlkj.cartweb.controller;

import com.hlkj.cartweb.feign.TbBrandClient;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cloud.client.ServiceInstance;
import org.springframework.cloud.client.discovery.DiscoveryClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;

import java.io.IOException;
import java.util.List;

@RestController
public class TbBrandController {
    @Autowired
    private TbBrandClient tbBrandClient;

    @GetMapping(value = "/showAllBrands")
    public String getAllBrands(){
        return tbBrandClient.findAllBrands();
    }
    @GetMapping(value = "/showSomeBrands")
    public String getSomeBrands(){
        return tbBrandClient.findAllBrands();
    }
}
